
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script type="text/javascript" src="http://cache.amap.com/lbs/static/addToolbar.js"></script>
<script type="text/javascript">

    function displayErrorTab() {
        if ($('#pumpstationForm').form('validate')) {
            return true;
        } else {
            var invalid=$('.validatebox-invalid','#pumpstationForm').first();
            var parentTable=invalid.parents('table');
            var table=parentTable[0];
            var id=$(table).attr('id');
            //alert("id="+id);
            var index=Number(id.substring(id.length-1));
            $('#tabs_pumpstation').tabs('select',index);
            $('#pumpstationForm').form('validate');
            return false;
        }
    }

    function clearPumpstationForm(){
        $('#pumpstationForm').form('clear');
    }

    function addPumpstation() {
        clearPumpstationForm();
        $('#obj_id').val('');
        $("#oprt").val("add");
        map = new AMap.Map('map', {
            resizeEnable: true,
            zoom:12,
            center: [102.710212,25.0548]
        });
        map.plugin(["AMap.ToolBar"], function() {
            map.addControl(new AMap.ToolBar());
        });
    }

    function editPumpstation(id) {
        clearPumpstationForm();
        $("#oprt").val("update");
        $.ajax({url:"__URL__/get_station_json",data:{'id':id},dataType:"json",success:function(json, textStatus){
            console.log(json.ps_opr_names);
            jQuery('#pumpstationForm').form('load',{
                "id": json.id,
                "ps_id": json.ps_id,
                "ps_sysid": json.ps_sysid,
                "ps_name": json.ps_name,
                "ps_catg1": json.ps_catg1,
                "ps_catg2": json.ps_catg2,
                "ps_catg3": json.ps_catg3,
                'ps_addr':json.ps_addr,
                'ps_area':json.ps_area,
                'mobile':json.mobile,
                'ps_tel':json.ps_tel,
                'ps_opr':json.ps_opr,
                'opr_temp':json.ps_opr_names,
                'ps_point':json.ps_point,
                'ps_sysid':json.ps_sysid,
                'ps_scale':json.ps_scale,
                'ps_x':json.ps_x,
                'ps_y':json.ps_y,
                'ps_elev':json.ps_elev,
                'ps_region':json.ps_region,
                'ps_area':json.ps_area,
                'ps_svc_scope':json.ps_svc_scope,
                'ps_svc_area':json.ps_svc_area,
                'ps_p_num':json.ps_p_num,
                'ps_bkp_num':json.ps_bkp_num,
                'ps_drain_amt':json.ps_drain_amt,
                'ps_dev_cap':json.ps_dev_cap,
                'ps_power_amt':json.ps_power_amt,
                'ps_rwp_num':json.ps_rwp_num,
                'ps_bkrwp_num':json.ps_bkrwp_num,
                'ps_rwdrain_amt':json.ps_rwdrain_amt,
                'ps_rwdrain_dsgn':json.ps_rwdrain_dsgn,
                'ps_rwdev_cap':json.ps_rwdev_cap,
                'ps_rwpower_amt':json.ps_rwpower_amt,
                'ps_sp_num':json.ps_sp_num,
                'ps_bksp_num':json.ps_bksp_num,
                'ps_sdrain_amt':json.ps_sdrain_amt,
                'ps_sdrain_dsgn':json.ps_sdrain_dsgn,
                'ps_sdev_cap':json.ps_sdev_cap,
                'ps_spower_amt':json.ps_spower_amt,
                'ps_ro_dsgn':json.ps_ro_dsgn,
                'ps_rtp_dsgn':json.ps_rtp_dsgn,
                'ps_up_p':json.ps_up_p,
                'ps_down_p':json.ps_down_p,
                'ps_to_riv':json.ps_to_riv,
                'ps_w_purific':json.ps_w_purific,
                'ps_int_num':json.ps_int_num,
                'ps_out_num':json.ps_out_num,
                'ps_img':json.ps_img,

                'ps_sts':json.ps_sts,
                'ps_run_typ':json.ps_run_typ,
                'ps_guard_typ':json.ps_guard_typ,
                'ps_shift_sys':json.ps_shift_sys,
                'ps_guard_num':json.ps_guard_num,

                'ps_ename':json.ps_ename,
                'ps_bulid_dept':json.ps_bulid_dept,
                'ps_dsgn_dept':json.ps_dsgn_dept,
                'ps_constr_dept':json.ps_constr_dept,
                'ps_surv_dept':json.ps_surv_dept,
                'ps_prop_dept':json.ps_prop_dept,
                'ps_mt_dept':json.ps_mt_dept,
                'ps_finish_dt':json.ps_finish_dt,
                'ps_svc_dt':json.ps_svc_dt,
                'ps_recon_dt':json.ps_recon_dt,

                'dev_gate':json.dev_gate,
                'dev_ipc':json.dev_ipc,
                'dev_sec_sys':json.dev_sec_sys,
                'dev_screemach':json.dev_screemach,
                'dev_conv':json.dev_conv,
                'dev_press':json.dev_press,
                'dev_deodorizer':json.dev_deodorizer,
                'dev_vent':json.dev_vent,
                'dev_hoist':json.dev_hoist,
                'dev_gen':json.dev_gen,
                'dev_valve':json.dev_valve,
                'dev_penstock':json.dev_penstock,

                'ps_plan':json.ps_plan,
                'ps_plans':json.ps_plans,
                'ps_groprc_dl':json.ps_groprc_dl,
                'ps_mapno':json.ps_mapno,
                'ps_datasrc':json.ps_datasrc,
                'ps_data_dt':json.ps_data_dt,
                'ps_rpt_dept':json.ps_rpt_dept,
                'ps_rpt_dt':json.ps_rpt_dt,
                'note':json.note,
            });
            if(json.ps_plan != ''){
                $('#ps_plan_img').attr('src', json.ps_plan);
            }
            if(json.ps_plans != ''){
                $('#ps_plans_img').attr('src', json.ps_plans);
            }
            if(json.ps_img != ''){
                $('#ps_img_img').attr('src', json.ps_img);
            }
            var s_g_url = '/Manage/AdminSGallery/get_s_gallery_by_s?s_type=1&s_id='+json.id;
            $.getJSON(s_g_url, function(res_data){
                var obj = '';
                for(var i=0;i<res_data.length;i++){
                    obj = res_data[i];
                    add_s_gallery(1, obj.img_type, obj.path, 's_'+obj.img_type+'_div', obj.id);
                    <?php if(I('get.justsee')){?>
                    hide_s_g_img_tip()
                    <?php }?>
                }
            });
            //标记当前泵机
            $('#pumpstation_id').val(json.id);
            //在地图上标出来
            var gps = json.ps_point;
            if(json.ps_point != ''){
                gps = json.ps_point.split(",");
                gps = [gps[0],gps[1]];
//                gps = [102.710212,25.0548];
                $('#long').val(gps[0]);
                $('#lat').val(gps[1]);
            }else{
                gps = [102.710212,25.0548];
            }
            map = new AMap.Map('map', {
                resizeEnable: true,
                zoom:12,
                center: gps
            });
            map.plugin(["AMap.ToolBar"], function() {
                map.addControl(new AMap.ToolBar());
            });
            marker = new AMap.Marker({
                position: gps
            });
            marker.setMap(map);
            markers.push(marker);
            $('#getPoint').linkbutton('enable');
//            setFormFocus('#pumpstationForm');
        },error:function(XMLHttpRequest, textStatus, errorThrown)
        {
            relogin(XMLHttpRequest, textStatus, errorThrown);
        }});
    }

    function formatFileName(name){
        var fname = name.substring(7,name.lastIndexOf("."));
        var fExtName = name.substring(name.lastIndexOf(".")+1);
        var len = fname.length-24;
        fname = fname.substring(0,len+1)+"."+fExtName;
        return fname;
    }

    function submitPumpstationForm() {
        if (displayErrorTab()) {
            var submitflag = jQuery("#oprt").val();
            var url = "";
            if (submitflag === "add")
                url = "__URL__/add";
            if (submitflag === "update")
                url = "__URL__/edit";
            $('#pumpstationForm').ajaxSubmit({
                url:url,
                dataType:'json',
                async: false,
                success: function(data) {
                    if (data.status=="1") {
                        $('#listDialog').dialog('close');
                        $.messager.show({title:'提示',msg:'保存泵站基础信息成功！',showType:'slide'});
                        var post_data = {'data':get_s_gallery_ids(), 's_id':data.id};
                        var url = '/Manage/AdminSGallery/add_s_gallery';
                        $.post(url, post_data, function(res_data){
                            $('#listDialog').dialog('close');
                        });
                    }else $.messager.alert('提示','操作失败！原因:'+data.msg,'error');
                }
            });
        }
    }

    //高德地图插件
    var map = new AMap.Map('map', {
        resizeEnable: true,
        zoom:12,
        center: [102.710212,25.0548]
    });
    map.plugin(["AMap.ToolBar"], function() {
        map.addControl(new AMap.ToolBar());
    });
    //地图获取gps坐标回调函数
    var markers = [];
    var callBackFn = function(e) {
        map.remove(markers);
        var marker = new AMap.Marker({
            map: map,
            position: [e.lnglat.getLng(), e.lnglat.getLat()]
        });
        markers.push(marker);
        $('#long').val(e.lnglat.getLng());
        $('#lat').val(e.lnglat.getLat());
        $('#gps').val(e.lnglat.getLng()+','+e.lnglat.getLat());
    };
    function getPoint(){
        $('#getPoint').linkbutton('disable');
        $('#stopListen').linkbutton('enable');
        map.on('click', callBackFn);
    }
    function stopPoiont(){
        $('#getPoint').linkbutton('enable');
        map.off('click', callBackFn);
    }
    function getLocation(){
        if($('#ps_address').val()==null||$.trim($('#ps_address').val())==''){
            $.messager.alert('提示','请填写地址后再定位！','error');
            return;
        }
        AMap.service(["AMap.PlaceSearch"], function() {
            var placeSearch = new AMap.PlaceSearch({ //构造地点查询类
                pageSize: 5,
                pageIndex: 1,
                city: "010", //城市
                map: map,
                panel: "panel"
            });
            //关键字查询
            var keyword = $('#ps_address').val();
            placeSearch.search(keyword);
        });
    }
    <?php if(I('get.justsee')){?>
        $('#tabs_pumpstation input').attr('readonly', true);
        $('#tabs_pumpstation select').attr('readonly', true);
        $('#tabs_pumpstation textarea').attr('readonly', true);
        $('#tabs_pumpstation #opr').attr('onclick', '');
        $('#getPoint,#stopListen').hide();
    <?php }?>
</script>
<form id="pumpstationForm" method="post"  action="">
    <input type="hidden" id="oprt" name="oprt" value="add">
    <input type="hidden" name="id" id="obj_id" />
    <div id="tabs_pumpstation" class="easyui-tabs"  style="height:500px;width:800px;" plain="true" <?php if(!I('get.justsee')){?>tools="#tab_tools_pumpstation"<?php }?>>
        <div title="基本信息" style="padding:10px;" fit="true">
            <table border="0" id='table0'>
                <tr>
                    <td>泵站名称：</td>
                    <td>
                        <input id="ps_name" class="easyui-validatebox" type="text" name="ps_name" style="width:400px" required="true"></input>
                    </td>
                </tr>
                <tr>
                    <td>排水泵站标识码：</td>
                    <td>
                        <input id="ps_name" class="easyui-textbox" type="text" name="ps_id" style="width:400px" required="true"></input>
                    </td>
                </tr>
                <tr>
                    <td>排水系统编码：</td>
                    <td>
                        <input id="ps_name" class="easyui-textbox" type="text" name="ps_sysid" style="width:400px" required="true"></input>
                    </td>
                </tr>
                <tr>
                    <td>泵站基类：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_catg3" id="ps_catg3" style="width:200px;" data-options="prompt:'{:LANG('pls_input')}',required:true">
                            {:pump_station_base_types_option()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>泵站大类：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_catg1" id="ps_catg1" style="width:200px;" data-options="prompt:'{:LANG('pls_input')}',required:true">
                            {:pump_station_types_option()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>泵站小类：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_catg2" id="ps_catg2" style="width:200px;" data-options="prompt:'{:LANG('pls_input')}',required:true">
                            {:pump_station_types_second_option()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>执勤电话：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="mobile" style="width:200px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>座机：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_tel" style="width:200px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>{:LANG('opr')}: </td>
                    <td>
                        <textarea id="opr" name="opr_temp" style="width: 300px;height: 50px;" readonly="true" onclick="open_dialog('/Manage/AdminMobileAdmin//show_mobile_admin?ids='+$('#opr_ids').val())"></textarea>
                        <input type="hidden" id="opr_ids" name="ps_opr">
                    </td>
                </tr>
                <tr>
                    <td>泵站简介：</td>
                    <td>
                        <textarea name="note" style="width:400px;height:60px"></textarea>
                    </td>
                </tr>
                <tr>
                    <td>泵站规模：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_scale" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:pump_station_scope_option()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>X坐标：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_x" precision="3" style="width:150px;"></input>
                    </td>
                    <td>应与泵站中心点坐标一致 87坐标</td>
                </tr>
                <tr>
                    <td>Y坐标：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_y" precision="3" style="width:150px;"></input>
                    </td>
                    <td>应与泵站中心点坐标一致 87坐标</td>
                </tr>
                <tr>
                    <td>地面高程(米)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_elev" precision="3" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>行政区划：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_region" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:pump_station_area_option()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>占地面积(平方米)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_area" precision="2" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>服务范围：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_svc_scope" style="width:400px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>服务面积(平方米)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_svc_area" precision="2" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>上游泵站名称：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_up_p" style="width:400px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>下游泵站名称：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_down_p" style="width:400px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>排入水体：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_to_riv" style="width:400px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>下游水质净化厂：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_w_purific" style="width:400px;"></input>
                    </td>
                </tr>
            </table>
        </div>
        <div title="位置信息" fit=true style="padding:10px;">
            <table border="0" id='table1'>
                <tr>
                    <td>泵站地址：</td>
                    <td colspan=3>
                        <input class="easyui-validatebox" required=true id='ps_addr' type="text" name="ps_addr" style="width:300px"></input>
                        <input id='gps' type="hidden" name="ps_point"  style="width:120px" readonly required=true></input>
<!--                        <span><a href="#" class="easyui-linkbutton" data-options="iconCls:'icon-search'" onclick='getLocation()'>地图定位</a></span>-->
                    </td>
                </tr>

                <tr>
                    <td>经度：</td>
                    <td>
                        <input class="easyui-validatebox" id='long' type="text"   style="width:120px" readonly required=true></input>
                    </td>
                    <td>纬度：</td>
                    <td>
                        <input class="easyui-validatebox" id='lat' type="text"  style="width:120px" readonly required=true></input>
                        <span><a id='getPoint' href="#" class="easyui-linkbutton" data-options="iconCls:'icon_ext icon-gps'" onclick='getPoint()'>点选经纬度</a></span>
                        <span><a id='stopListen' href="#" class="easyui-linkbutton"  data-options="iconCls:'icon-ok'" onclick="stopPoiont()">确定</a></span>
                    </td>
                </tr>
            </table>
            <div id="map" class="easyui-panel" data-options="fit:true,border:false">
            </div>
        </div>
        <div title="运行数据" fit=true style="padding:10px;">
            <table border="0"'>
                <tr>
                    <td>总水泵台数：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_p_num" style="width:150px;"></input>
                    </td>
                    <td>备用水泵台数：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_bkp_num" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>总排水能力(立方米/时)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_drain_amt" precision="4" style="width:150px;"></input>
                    </td>
                    <td>总装机容量(千瓦)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_dev_cap" precision="2" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>泵站总功率(千瓦)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_power_amt" precision="2" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>雨水泵台数：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_rwp_num" style="width:150px;"></input>
                    </td>
                    <td>备用雨水泵台数：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_bkrwp_num" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>雨水总排水能力(立方米/时)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_rwdrain_amt" precision="4" style="width:150px;"></input>
                    </td>
                    <td>设计雨水排水能力(立方米/时)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_rwdrain_dsgn" precision="4" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>雨水装机容量(千瓦)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_rwdev_cap" precision="2" style="width:150px;"></input>
                    </td>
                    <td>雨水泵站总功率(千瓦)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_rwpower_amt" precision="4" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>污水泵台数：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_sp_num" style="width:150px;"></input>
                    </td>
                    <td>备用污水泵台数：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_bksp_num" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>污水总排水能力(立方米/时)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_sdrain_amt" precision="4" style="width:150px;"></input>
                    </td>
                    <td>设计污水排水能力(立方米/时)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_sdrain_dsgn" precision="4" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>污水装机容量(千瓦)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_sdev_cap" precision="2" style="width:150px;"></input>
                    </td>
                    <td>污水泵站总功率(千瓦)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_spower_amt" precision="4" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>设计综合径流系数：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_ro_dsgn" precision="3" style="width:150px;"></input>
                    </td>
                    <td>设计暴雨重现期：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_rtp_dsgn" precision="1" style="width:150px;"></input>
                    </td>
                </tr>
                <tr>
                    <td>进水管渠数量(根)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_int_num" style="width:150px;"></input>
                    </td>
                    <td>出水管数量(根)：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_out_num" style="width:150px;"></input>
                    </td>
                </tr>
            </table>

        </div>
        <div title="设施状态" fit="true" style="padding:10px;">
            <table border="0" id='table0'>
                <tr>
                    <td>设施状态：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_sts" style="width:100px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:pump_station_status_option()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>运转类型：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_run_typ" style="width:100px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:ps_run_typ()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>值守类型：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_guard_typ" style="width:100px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:ps_guard_typ()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>轮班制度：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_shift_sys" style="width:100px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:ps_shift_sys()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>值守人数：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_guard_num" style="width:100px"></input>
                    </td>
                </tr>
            </table>
        </div>
        <div title="权属信息" fit="true" style="padding:10px;">
            <table border="0" id='table0'>
                <tr>
                    <td>所属工程：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_ename" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>建设单位：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_bulid_dept" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>设计单位：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_dsgn_dept" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>施工单位：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_constr_dept" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>监理单位：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_surv_dept" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>产权单位：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_prop_dept" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>维护单位：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_mt_dept" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>竣工日期：</td>
                    <td>
                        <input class="easyui-datebox" type="text" name="ps_finish_dt" style="width:100px"></input>
                    </td>
                </tr>
                <tr>
                    <td>投运日期：</td>
                    <td>
                        <input class="easyui-datebox" type="text" name="ps_svc_dt" style="width:100px"></input>
                    </td>
                </tr>
                <tr>
                    <td>改建日期：</td>
                    <td>
                        <input class="easyui-datebox" type="text" name="ps_recon_dt" style="width:100px"></input>
                    </td>
                </tr>

            </table>
        </div>
        <div title="配套设备" fit="true" style="padding:10px;">
            <table border="0" id='table0'>
                <tr>
                    <td width="80">闸门：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_gate" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                    <td width="80">工控系统：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_ipc" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td width="80">安防系统：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_sec_sys" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                    <td width="80">格栅除污机：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_screemach" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td width="80">输送机：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_conv" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                    <td width="80">压榨机：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_press" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td width="80">除臭设备：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_deodorizer" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                    <td width="80">通风设备：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_vent" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td width="80">起吊设备：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_hoist" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                    <td width="80">发电机：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_gen" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td width="80">阀门：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_valve" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                    <td width="80">河闸：</td>
                    <td>
                        <select class="easyui-combobox" name="dev_penstock" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:is_have()}
                        </select>
                    </td>
                </tr>
            </table>
        </div>
        <div title="资产信息" fit="true" style="padding:10px;">
            <table border="0" id='table0'>
                <tr>
                    <td>竣工决算价：</td>
                    <td>
                        <input class="easyui-numberbox" type="text" name="ps_groprc_dl" precision="3" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>图幅编号：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_mapno" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>数据来源：</td>
                    <td>
                        <select class="easyui-combobox" name="ps_datasrc" style="width:150px;" data-options="prompt:'{:LANG('pls_input')}'">
                            {:ps_datasrc()}
                        </select>
                    </td>
                </tr>
                <tr>
                    <td>数据获取日期：</td>
                    <td>
                        <input class="easyui-datebox" type="text" name="ps_data_dt" style="width:100px"></input>
                    </td>
                </tr>
                <tr>
                    <td>填报单位：</td>
                    <td>
                        <input class="easyui-textbox" type="text" name="ps_rpt_dept" style="width:400px"></input>
                    </td>
                </tr>
                <tr>
                    <td>填报日期：</td>
                    <td>
                        <input class="easyui-datebox" type="text" name="ps_rpt_dt" style="width:100px"></input>
                    </td>
                </tr>
            </table>
        </div>
        <div title="泵站影像资料" fit="true" style="padding:10px;">
            <table border="0">
                <tr>
                    <td>
                        <?php if(!I('get.justsee')){?><input id="ps_img_button" type="file" multiple="true" value="" /><?php }?>
                    </td>
                </tr>
                <tr>
                    <td>
<!--                        <img src="__PUBLIC__/img/no_pic.jpg" id="ps_img_img" width="800" height="600">-->
<!--                        <input type="hidden" name="ps_img" id="ps_img"/>-->
                    </td>
                </tr>
            </table>
            <div id="s_1_div"></div>
        </div>
        <div title="泵站平面图" fit="true" style="padding:10px;">
		图片大小请不要超过20M，格式可以为：jpg，png，bmp
            <table border="0">
                <tr>
                    <td>
                        <?php if(!I('get.justsee')){?><input id="ps_plan_button" type="file" multiple="true" value="" /><?php }?>
                    </td>
                </tr>
                <tr>
                    <td>
<!--                        <img src="__PUBLIC__/img/no_pic.jpg" id="ps_plan_img" width="800" height="600">-->
<!--                        <input type="hidden" name="ps_plan" id="ps_plan"/>-->
                    </td>
                </tr>
            </table>
            <div id="s_2_div"></div>
        </div>
        <div title="泵站剖面图" fit="true" style="padding:10px;">
		图片大小请不要超过20M，格式可以为：jpg，png，bmp
            <table border="0"'>
                <tr>
                    <td>
                        <?php if(!I('get.justsee')){?><input id="ps_plans_button" type="file" multiple="true" value="" /><?php }?>
                    </td>
                </tr>
                <tr>
                    <td>
<!--                        <img src="__PUBLIC__/img/no_pic.jpg" id="ps_plans_img" width="800" height="600">-->
<!--                        <input type="hidden" name="ps_plans" id="ps_plans"/>-->
                    </td>
                </tr>
            </table>
            <div id="s_3_div"></div>
        </div>

    </div>
    <?php if(!I('get.justsee')){?>
    <div id="tab_tools_pumpstation">
        <a href="#" class="easyui-linkbutton" iconCls="icon-save" plain="true" onclick="javascript:submitPumpstationForm();">保存泵站基本信息</a>
    </div>
    <?php }?>
    <div id="img_show_dlg" class="easyui-dialog" closed="true" resizable='true' maximizable="true" modal="true" title="图片查看" style="width:440px;height:400px;padding:10px">
       <a target="_blank">下载</a>
        <img width="380">
    </div>
</form>
<script>
    $('#ps_img_button').uploadify({
        'swf'      : '/Public/uploadfy/uploadify.swf',
        'uploader' : '/Manage/Admin/uploadify?ut=1&s_type=1&s_id='+get_s_id()+'&img_type=1',
        'buttonText' : '上传泵站现场照片',
        'onUploadSuccess' : function(file, data, response) {
            var imgname = data.trim();
//            $('#ps_img_img').attr('src', imgname);
//            $('#ps_img').val(imgname);
            add_s_gallery(1, 1, imgname, 's_1_div', '');
            <?php if(I('get.justsee')){?>
            hide_s_g_img_tip()
            <?php }?>
        }
    });
    $('#ps_plan_button').uploadify({
        'swf'      : '/Public/uploadfy/uploadify.swf',
        'uploader' : '/Manage/Admin/uploadify?ut=1&s_type=1&s_id='+get_s_id()+'&img_type=2',
        'buttonText' : '上传平面图',
        'onUploadSuccess' : function(file, data, response) {
            var imgname = data.trim();
//            $('#ps_plan_img').attr('src', imgname);
//            $('#ps_plan').val(imgname);
            add_s_gallery(1, 2, imgname, 's_2_div', '');
            <?php if(I('get.justsee')){?>
            hide_s_g_img_tip()
            <?php }?>
        }
    });
    $('#ps_plans_button').uploadify({
        'swf'      : '/Public/uploadfy/uploadify.swf',
        'uploader' : '/Manage/Admin/uploadify?ut=1&s_type=1&s_id='+get_s_id()+'&img_type=3',
        'buttonText' : '上传剖面图',
        'onUploadSuccess' : function(file, data, response) {
            var imgname = data.trim();
//            $('#ps_plans_img').attr('src', imgname);
//            $('#ps_plans').val(imgname);
            add_s_gallery(1, 3, imgname, 's_3_div', '');
            <?php if(I('get.justsee')){?>
            hide_s_g_img_tip()
            <?php }?>
        }
    });
</script>